package cn.yunhe.biz;

import cn.yunhe.bean.HotelArea;
import cn.yunhe.dao.HotelAreaMapper;
import cn.yunhe.util.SqlSessionFactoryUtil;
import org.apache.ibatis.session.SqlSession;

import java.util.List;

public class HotelAreaService {
    SqlSession session = SqlSessionFactoryUtil.getSqlSession();
    HotelAreaMapper hotelAreaMapper = session.getMapper(HotelAreaMapper.class);
    public HotelArea getHotelareaByName(String areaname){
        return  hotelAreaMapper.searchHotelAreaByName(areaname);
    }

    public List<HotelArea>  getAllHotelArea(){
        return  hotelAreaMapper.searchAllHotelArea();
    }
}
